//
//  LSZKnowChristManager.m
//  JKFuYinProject
//
//  Created by 九酷 on 2017/9/30.
//  Copyright © 2017年 LC. All rights reserved.
//

#import "LSZKnowChristManager.h"

@implementation LSZKnowChristManager
-(id)initWithKnowChristManager :(NSDictionary *)dic;
{
    self = [super init];
    if (self) {
        NSMutableArray * arrayMut = [NSMutableArray array];
        self.mutDataArray = [NSMutableArray array];
        if ([[dic valueForKey:@"data"] isKindOfClass:[NSString class]]) {
            return self;
        }
        if ([[dic valueForKey:@"data"] isKindOfClass:[NSNumber class]]) {
            return self;
        }
        if (![dic valueForKey:@"data"]) {
            return self;
        }
        NSArray * arrayData = dic[@"data"];
        
        for (NSDictionary * diction in arrayData) {
            LSZKnowChristMg *  KnowChristMg = [[LSZKnowChristMg alloc]init];
            KnowChristMg.id_id = [NSString stringWithFormat:@"%@",diction[@"id"]];
            KnowChristMg.title = [NSString stringWithFormat:@"%@",diction[@"title"]];
            
            if ([diction valueForKey:@"pic"]) {
                KnowChristMg.pic = [NSString stringWithFormat:@"%@",diction[@"pic"]];
            }
            if ([diction valueForKey:@"hasChild"]) {
                KnowChristMg.hasChild = [NSString stringWithFormat:@"%@",diction[@"hasChild"]];
            }
            if ([diction valueForKey:@"url"]) {
                KnowChristMg.url = [NSString stringWithFormat:@"%@",diction[@"url"]];
            }
            [arrayMut addObject:KnowChristMg];
        }
        self.mutDataArray = arrayMut;
    }
    return self;
}
@end
@implementation LSZKnowChristMg
@end
